package com.dnjn.happiness.survey.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.dnjn.happiness.common.core.annotation.Excel;
import com.dnjn.happiness.common.core.web.domain.BaseEntity;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 考核对象 svy_check_item
 *
 * @author happiness
 * @date 2024-04-01
 */
@Schema(name = "CheckItem", description = "考核")
@Accessors(chain = true)
@Getter
@Setter
@TableName("svy_check_item")
public class CheckItem extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** PK */
    @JsonSerialize(using = ToStringSerializer.class)
    @TableId(value = "check_item_id", type = IdType.ASSIGN_ID)
    private Long checkItemId;

    


    /** $column.columnComment */
    @Schema(description = "${comment}")
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    private Long checkId;

    /** 发起人id */
    @Schema(description = "发起人id")
    @Excel(name = "发起人id")
    private Long initiatorId;

    /** 被考核人id */
    @Schema(description = "被考核人id")
    @Excel(name = "被考核人id")
    private Long userId;

    /** 被考核人上级id */
    @Schema(description = "被考核人上级id")
    @Excel(name = "被考核人上级id")
    private Long superiorUserId;

    /** 被考核人下级id */
    @Schema(description = "被考核人下级id")
    @Excel(name = "被考核人下级id")
    private Long subordinateUserId;

    /** 考核状态N,Y */
    @Schema(description = "考核状态N,Y")
    @Excel(name = "考核状态N,Y")
    private String checkStatus;

    /** 考核类型：STAFF-员工;MANAGER */
    @Schema(description = "考核类型：STAFF-员工;MANAGER")
    @Excel(name = "考核类型：STAFF-员工;MANAGER")
    private String checkType;

    /** 考核上级分数 */
    @Schema(description = "考核上级分数")
    @Excel(name = "考核上级分数")
    private Long superiorCheckScore;

    /** 考核下级分数 */
    @Schema(description = "考核下级分数")
    @Excel(name = "考核下级分数")
    private Long subordinateCheckScore;

    /** 考核上级结果 */
    @Schema(description = "考核上级结果")
    @Excel(name = "考核上级结果")
    private String superiorCheckResult;

    /** 考核下级结果 */
    @Schema(description = "考核下级结果")
    @Excel(name = "考核下级结果")
    private String subordinateCheckResult;

    /** $column.columnComment */
    @Schema(description = "${comment}")
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    private Long tikuTagsId;

    /** 是否删除|0-否 1-是|valid */
    @Schema(description = "是否删除|0-否 1-是|valid")
    @Excel(name = "是否删除|0-否 1-是|valid")
    private String deleted;

    @Schema(description = "考核上级状态")
    private String superiorStatus;

    @Schema(description = "考核下级状态")
    private String subordinateStatus;

    @TableField(exist = false)
    private String avatar;
    @TableField(exist = false)
    private String nickName;

    @Schema(description = "考核绩效分数")
    private Integer checkItemScore;

    @Schema(description = "考核绩效结果")
    private String checkItemResult;




    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("checkItemId", getCheckItemId())
                .append("checkId", getCheckId())
                .append("initiatorId", getInitiatorId())
                .append("userId", getUserId())
                .append("superiorUserId", getSuperiorUserId())
                .append("subordinateUserId", getSubordinateUserId())
                .append("checkStatus", getCheckStatus())
                .append("checkType", getCheckType())
                .append("superiorCheckScore", getSuperiorCheckScore())
                .append("subordinateCheckScore", getSubordinateCheckScore())
                .append("superiorCheckResult", getSuperiorCheckResult())
                .append("subordinateCheckResult", getSubordinateCheckResult())
                .append("tikuTagsId", getTikuTagsId())
                .append("remark", getRemark())
                .append("createBy", getCreateBy())
                .append("createTime", getCreateTime())
                .append("updateBy", getUpdateBy())
                .append("updateTime", getUpdateTime())
                .append("deleted", getDeleted())
                .append("version", getVersion())
                .toString();
    }
}
